home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / c / cenvid9.zip / DOSTIME.BAT < prev    next >
DOS Batch File  |  1994-03-04  |  537b  |  23 lines

  1. @echo off
  2. REM *********************************************
  3. REM *** DosTime - CEnvi example program for   ***
  4. REM *** ver.1     showing the DOS system time ***
  5. REM *********************************************
  6.  
  7. cenvi %0.bat
  8. GOTO CENVI_EXIT
  9.  
  10. printf("Displaying DOS system time; press any key to end:\n")
  11.  
  12. while( !kbhit() ) {
  13.    reg.ah = 0x2C
  14.    interrupt(0x21,reg)
  15.    printf("\r%2d:%02d:%02d.%02d",reg.ch,reg.cl,reg.dh,reg.dl)
  16. }
  17.  
  18. while( kbhit() ) getch()         // flush keyboard buffer
  19. printf("\n")
  20.  
  21.  
  22. :CENVI_EXIT
  23.